import Vue from "vue";
import VueRouter from "vue-router";

Vue.use(VueRouter);

const routes = [
  /* 自我介绍 */
  {
    path: "/introduction",
    name: "Introduction",
    component: () => import("../views/introduction"),
  },
  /* 今日饮食 */
  {
    path: "/dailyfood",
    name: "dailyfood",
    // component:BasicLayout,
    component: () => import("../views/dailyfood"),
    // children:[{
    //   component: () => import('../views/dailyfood')
    // }]
  },
  /* 健康记录 */
  {
    path: "/health",
    name: "health",
    component: () => import("../views/health"),
  },
  /* 我的 */
  {
    path: "/my",
    name: "my",
    component: () => import("../views/my"),
  },
  /* 运动 */
  {
    path: "/sport",
    name: "sport",
    component: () => import("../views/sport"),
  },
  /* 体态特征 */
  {
    path: "/body",
    name: "body",
    component: () => import("../views/body"),
  },
  /* 语音交互 */
  {
    path: "/ask",
    name: "ask",
    component: () => import("../views/ask"),
  },
  {
    path: "/",
    name: "Index",
    component: () => import("../views/index/index.vue"),
  },
  {
    path: "/grid",
    name: "Grid",
    component: () => import("../views/grid/grid.vue"),
  },
  {
    path: "/text",
    name: "TEXT",
    component: () => import("../views/textscr/index.vue"),
  },
  {
    path: "/geci",
    name: "GECI",
    component: () => import("../views/geci/index.vue"),
  },
  {
    path: "/gecit",
    name: "GECI",
    component: () => import("../views/geci2/index.vue"),
  },
];

const router = new VueRouter({
  mode: "hash",
  base: process.env.BASE_URL,
  routes,
});

export default router;
